package com.bskj.kuaifu.bean.vo.resp;

import com.bskj.common.bean.model.ParkInfo;
import com.bskj.common.bean.model.ParkingLotCustomer;
import com.bskj.common.utils.DateTimeUtil;

public class ParkinfoAppealVo {
	private Integer id;
	private String parkName;
	private String carNo;
	private String inTime;
	private String outTime;
	private Integer allMoney;
	private Integer couponMoney;
	private Integer money;
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public String getParkName() {
		return parkName;
	}
	public void setParkName(String parkName) {
		this.parkName = parkName;
	}
	public String getCarNo() {
		return carNo;
	}
	public void setCarNo(String carNo) {
		this.carNo = carNo;
	}
	public String getInTime() {
		return inTime;
	}
	public void setInTime(String inTime) {
		this.inTime = inTime;
	}
	public String getOutTime() {
		return outTime;
	}
	public void setOutTime(String outTime) {
		this.outTime = outTime;
	}
	public Integer getAllMoney() {
		return allMoney;
	}
	public void setAllMoney(Integer allMoney) {
		this.allMoney = allMoney;
	}
	public Integer getCouponMoney() {
		return couponMoney;
	}
	public void setCouponMoney(Integer couponMoney) {
		this.couponMoney = couponMoney;
	}
	public Integer getMoney() {
		return money;
	}
	public void setMoney(Integer money) {
		this.money = money;
	}
	
	public ParkinfoAppealVo setParinfoAppealVo(ParkInfo parkInfo,ParkingLotCustomer parkingLotCustomer) throws Exception {
		ParkinfoAppealVo parkinfoAppealVo=new  ParkinfoAppealVo();
		parkinfoAppealVo.setId(parkInfo.getId());
		parkinfoAppealVo.setParkName(parkingLotCustomer.getName());
		parkinfoAppealVo.setCarNo(parkInfo.getCarNo());
		parkinfoAppealVo.setInTime(DateTimeUtil.date2String(parkInfo.getInTime()));
		parkinfoAppealVo.setOutTime(DateTimeUtil.date2String(parkInfo.getOutTime()));
		parkinfoAppealVo.setAllMoney(parkInfo.getCharge());
		parkinfoAppealVo.setCouponMoney(parkInfo.getCharge()-parkInfo.getNeedPayCharge());
		parkinfoAppealVo.setMoney(parkInfo.getNeedPayCharge());
		return parkinfoAppealVo;
	}
}
